/**
 * Copyright &copy; 2012-2016 <a href="https://github.com/thinkgem/jeesite">JeeSite</a> All rights reserved.
 */
package com.thinkgem.jeesite.modules.hk.shop.entity.order;

import org.hibernate.validator.constraints.Length;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.thinkgem.jeesite.modules.hk.sys.entity.user.HkUser;
import com.thinkgem.jeesite.modules.sys.entity.Area;
import java.util.List;
import com.google.common.collect.Lists;

import com.thinkgem.jeesite.common.persistence.DataEntity;

/**
 * 用户订单管理Entity
 * @author 罗天文
 * @version 2018-08-22
 */
public class HkShopUserOrder extends DataEntity<HkShopUserOrder> {
	
	private static final long serialVersionUID = 1L;
	private String ordernumber;		// 订单号
	private String addressid;		// 地址
	private String productIntegral;		// 产品乐币
	private Date paytime;		// 支付时间
	private String freightIntegral;		// 快递乐币
	private String integral;		// 乐币
	private HkUser hkUserId;		// 自媒体商户id
	private String paytype;		// 支付类型
	private String state;		// 订单状态
	private Date selltime;		// 售出时间
	private Date limittime;		// 限制时间
	private String afterstate;		// 售后状态
	private Date confirmdate;		// 成交时间
	private HkUser user;		// 用户id
	private String consignee;		// 收货人
	private String phone;		// 手机号
	private Area area;		// 区
	private String address;		// 地址
	private Area province ;		// 省
	private Area city ;		// 市
	private String reason;		// 关闭订单原因
	private String courier;		// 快递公司
	private String couriernumber;		// 快递单号
	private Date delivertime;		// 发货时间
	private Date beginCreateDate;		// 开始 下单时间
	private Date endCreateDate;		// 结束 下单时间
	private List<HkShopUserOrderDetail> hkShopUserOrderDetailList = Lists.newArrayList();		// 子表列表
	
	public HkShopUserOrder() {
		super();
	}

	public HkShopUserOrder(String id){
		super(id);
	}

	@Length(min=0, max=20, message="订单号长度必须介于 0 和 20 之间")
	public String getOrdernumber() {
		return ordernumber;
	}

	public void setOrdernumber(String ordernumber) {
		this.ordernumber = ordernumber;
	}
	
	@Length(min=0, max=32, message="地址长度必须介于 0 和 32 之间")
	public String getAddressid() {
		return addressid;
	}

	public void setAddressid(String addressid) {
		this.addressid = addressid;
	}
	
	@Length(min=0, max=11, message="产品乐币长度必须介于 0 和 11 之间")
	public String getProductIntegral() {
		return productIntegral;
	}

	public void setProductIntegral(String productIntegral) {
		this.productIntegral = productIntegral;
	}
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	public Date getPaytime() {
		return paytime;
	}

	public void setPaytime(Date paytime) {
		this.paytime = paytime;
	}
	
	@Length(min=0, max=11, message="快递乐币长度必须介于 0 和 11 之间")
	public String getFreightIntegral() {
		return freightIntegral;
	}

	public void setFreightIntegral(String freightIntegral) {
		this.freightIntegral = freightIntegral;
	}
	
	@Length(min=0, max=11, message="乐币长度必须介于 0 和 11 之间")
	public String getIntegral() {
		return integral;
	}

	public void setIntegral(String integral) {
		this.integral = integral;
	}
	
	public HkUser getHkUserId() {
		return hkUserId;
	}

	public void setHkUserId(HkUser hkUserId) {
		this.hkUserId = hkUserId;
	}
	
	@Length(min=0, max=50, message="支付类型长度必须介于 0 和 50 之间")
	public String getPaytype() {
		return paytype;
	}

	public void setPaytype(String paytype) {
		this.paytype = paytype;
	}
	
	@Length(min=0, max=2, message="订单状态长度必须介于 0 和 2 之间")
	public String getState() {
		return state;
	}

	public void setState(String state) {
		this.state = state;
	}
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	public Date getSelltime() {
		return selltime;
	}

	public void setSelltime(Date selltime) {
		this.selltime = selltime;
	}
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	public Date getLimittime() {
		return limittime;
	}

	public void setLimittime(Date limittime) {
		this.limittime = limittime;
	}
	
	@Length(min=0, max=3, message="售后状态长度必须介于 0 和 3 之间")
	public String getAfterstate() {
		return afterstate;
	}

	public void setAfterstate(String afterstate) {
		this.afterstate = afterstate;
	}
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	public Date getConfirmdate() {
		return confirmdate;
	}

	public void setConfirmdate(Date confirmdate) {
		this.confirmdate = confirmdate;
	}
	
	public HkUser getUser() {
		return user;
	}

	public void setUser(HkUser user) {
		this.user = user;
	}
	
	@Length(min=0, max=100, message="收货人长度必须介于 0 和 100 之间")
	public String getConsignee() {
		return consignee;
	}

	public void setConsignee(String consignee) {
		this.consignee = consignee;
	}
	
	@Length(min=0, max=20, message="手机号长度必须介于 0 和 20 之间")
	public String getPhone() {
		return phone;
	}

	public void setPhone(String phone) {
		this.phone = phone;
	}
	
	public Area getArea() {
		return area;
	}

	public void setArea(Area area) {
		this.area = area;
	}
	
	@Length(min=0, max=200, message="地址长度必须介于 0 和 200 之间")
	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public Area getProvince() {
		return province;
	}

	public void setProvince(Area province) {
		this.province = province;
	}

	public Area getCity() {
		return city;
	}

	public void setCity(Area city) {
		this.city = city;
	}

	@Length(min=0, max=200, message="关闭订单原因长度必须介于 0 和 200 之间")
	public String getReason() {
		return reason;
	}

	public void setReason(String reason) {
		this.reason = reason;
	}
	
	@Length(min=0, max=50, message="快递公司长度必须介于 0 和 50 之间")
	public String getCourier() {
		return courier;
	}

	public void setCourier(String courier) {
		this.courier = courier;
	}
	
	@Length(min=0, max=50, message="快递单号长度必须介于 0 和 50 之间")
	public String getCouriernumber() {
		return couriernumber;
	}

	public void setCouriernumber(String couriernumber) {
		this.couriernumber = couriernumber;
	}
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	public Date getDelivertime() {
		return delivertime;
	}

	public void setDelivertime(Date delivertime) {
		this.delivertime = delivertime;
	}
	
	public Date getBeginCreateDate() {
		return beginCreateDate;
	}

	public void setBeginCreateDate(Date beginCreateDate) {
		this.beginCreateDate = beginCreateDate;
	}
	
	public Date getEndCreateDate() {
		return endCreateDate;
	}

	public void setEndCreateDate(Date endCreateDate) {
		this.endCreateDate = endCreateDate;
	}
		
	public List<HkShopUserOrderDetail> getHkShopUserOrderDetailList() {
		return hkShopUserOrderDetailList;
	}

	public void setHkShopUserOrderDetailList(List<HkShopUserOrderDetail> hkShopUserOrderDetailList) {
		this.hkShopUserOrderDetailList = hkShopUserOrderDetailList;
	}
}